//
//  ZHFNetworkManager+Extensions.swift
//  zhihuifan
//
//  Created by apple on 2017/8/17.
//  Copyright © 2017年 youyou. All rights reserved.
//

import Foundation
//MARK: - 首页数据加载
extension ZHFNetworkManager{
    //MARK:- 推荐商家
    func loadRecommendStore(completion:@escaping (_ json:[[String:AnyObject]]?,_ isSuccess:Bool)->()){
        let urlstring = "welcome/getRecommended"
        let parameters = ["platform":"1","param":["cityCode":cityCode,"latitude":latitude,"longitude":longitude]] as [String : Any]
        request(requestMethod: .POST, urlString: urlstring, parameters: parameters as [String : AnyObject]) { (json, isSuccess) in
            let result = json?["statuses"] as? [[String:AnyObject]]
            completion(result, isSuccess)
        }
    }
}
